package com.sc.nft.controller;


import com.sc.nft.annotation.UserLogin;
import com.sc.nft.entity.dto.NewSecondCollectionPayDTO;
import com.sc.nft.pool.UserPool;
import com.sc.nft.service.NewSecondCollectionCommonService;
import com.sc.nft.sup.Result;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;
import lombok.RequiredArgsConstructor;
import lombok.extern.slf4j.Slf4j;
import org.springframework.http.MediaType;
import org.springframework.validation.annotation.Validated;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

@Slf4j
@RequiredArgsConstructor
@RestController
@RequestMapping("/pay/second")
@Api(tags = "二级支付接口")
public class SecondPayController {

    private final NewSecondCollectionCommonService newSecondCollectionCommonService;

    @PostMapping(value = "/walletPay", produces = MediaType.APPLICATION_JSON_VALUE)
    @ApiOperation(value = "2级钱包支付", httpMethod = "POST", produces = MediaType.APPLICATION_JSON_VALUE)
    @UserLogin
    public Result newSecondCollectionPay(@RequestBody @Validated NewSecondCollectionPayDTO newSecondCollectionPayDTO) {
        return Result.fail("请下载最新版本");
//        return Result.success(newSecondCollectionCommonService.newSecondCollectionPay(UserPool.getUser(), newSecondCollectionPayDTO));
    }
}
